package com.example.edu.school.user.impl;

import com.example.edu.school.user.Visitable;
import com.example.edu.school.visitor.Visitor;

public class Student implements Visitable {

    public Student(String name, String identity, String classOrigin) {
        this.name = name;
        this.identity = identity;
        this.classOrigin = classOrigin;
    }

    public String classOrigin;

    public String name;

    public String identity;

    public int ranking() {
        return (int) (Math.random() * 100);
    }

    @Override
    public void accept(Visitor visitor) {
        visitor.visit(this);
    }
}
